public class HuiWen {
   public static void main(String args[]) {
     int sum=0;
     int i=0;
     int tmp=Integer.parseInt(args[0]);
     int rec=tmp;
     if(tmp<0) {
        System.out.println("Error");
     }
     else {
         while(tmp!=0){
			i = tmp%10;
			sum =sum*10+i;
			tmp /= 10;
		}
        
       System.out.println(sum);  
       
     }  
     if(sum==rec)System.out.println("是回文");
     else System.out.println("不是回文"); 
   }
}
    
   
